package zuoye;

import java.io.Serializable;

public class Product implements Serializable {
	private String factoryaddr;
	private boolean discount;
	private String name;
	private int itemno;
	private double price;
	private String unit;
	private int stockcount;
	private int gouMaiNum;

	public Product() {
		super();
	}

	public Product(boolean discount, int itemno, double price, int gouMaiNum,
			int stockcount) {
		super();
		this.discount = discount;
		this.itemno = itemno;
		this.price = price;
		this.gouMaiNum = gouMaiNum;
		this.stockcount = stockcount;
	}

	public Product(String factoryaddr, boolean discount, String name,
			int itemno, double price, String unit, int stockcount) {
		super();
		this.factoryaddr = factoryaddr;
		this.discount = discount;
		this.name = name;
		this.itemno = itemno;
		this.price = price;
		this.unit = unit;
		this.stockcount = stockcount;
	}

	public String getFactoryaddr() {
		return factoryaddr;
	}

	public void setFactoryaddr(String factoryaddr) {
		this.factoryaddr = factoryaddr;
	}

	public boolean getDiscount() {
		return discount;
	}

	public void setDiscount(boolean discount) {
		this.discount = discount;
	}

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public int getItemno() {
		return itemno;
	}

	public void setItemno(int itemno) {
		this.itemno = itemno;
	}

	public double getPrice() {
		return price;
	}

	public void setPrice(double price) {
		this.price = price;
	}

	public String getUnit() {
		return unit;
	}

	public void setUnit(String unit) {
		this.unit = unit;
	}

	public int getStockcount() {
		return stockcount;
	}

	public void setStockcount(int stockcount) {
		this.stockcount = stockcount;
	}

	public int getGouMaiNum() {
		return gouMaiNum;
	}

	public void setGouMaiNum(int gouMaiNum) {
		this.gouMaiNum = gouMaiNum;
	}

	@Override
	public String toString() {
		return "Product [factoryaddr=" + factoryaddr + ", discount=" + discount
				+ ", name=" + name + ", itemno=" + itemno + ", price=" + price
				+ ", unit=" + unit + ", stockcount=" + stockcount + "]";
	}

	public String gouWuChe() {
		return "itemno=" + itemno + ", gouMaiNum=" + gouMaiNum + ", discount="
				+ discount + ", price=" + price;
	}
}
